home *** CD-ROM | disk | FTP | other *** search
/ BBS Toolkit / BBS Toolkit.iso / doors_2 / wmail220.zip / WMSTRUCT.220 < prev    next >
Text File  |  1992-01-10  |  11KB  |  239 lines

  1. WMAIL 2.2 - Copyright 1990,91 by Silvan Calarco -
  2.  
  3.     ────────────────────────────────────────
  4.     Structures of files managed by WMAIL 2.2
  5.     ────────────────────────────────────────
  6.  
  7. The following structures are created in Turbo Pascal; look at following
  8. table for type compatibility.
  9.  
  10. Turbo Pascal  C language    Length
  11. ────────────  ────────────  ───────
  12. Byte          Char          1 byte
  13. Char          Char          1 byte
  14. Integer       Int           2 bytes
  15. Word          Unsigned Int  2 bytes
  16. Longint       Long          4 bytes
  17. ────────────  ────────────  ───────
  18.  
  19. String[] format uses a byte more than the number specified in brackets, as
  20. the first one (String[0]) contains string length.
  21.  
  22. ───────────────────────────────────────────────────────────────────────────
  23.  
  24.  
  25. { ***** Configuration file structures *********************************** }
  26.  
  27.  
  28.    SetRec=Record       { >>>>> file WMAIL.PRM <<<<< }
  29.              Version:Word; { 4: WMail 2.0  5: WMail 2.1  9: WMail 2.2 }
  30.              Sysop:String[30];
  31.              Key:String[16];
  32.              Aka:Array[0..10] of  { Aka 0 is primary address }
  33.                  Record
  34.                     Zone,Net,Node,Point:Integer;
  35.                     Domain:String[20];
  36.                  end;
  37.              FakeNet:Word;
  38.              ZoneGate:Array[1..10] of
  39.                       Record
  40.                          Net,Node:Integer;
  41.                       end;
  42.              Active_Options:Byte; { Bit mapped:
  43.                                         0: Import dupes
  44.                                         1: Import bad messages
  45.                                         2: Do statistics
  46.                                         3: Use log file
  47.                                         4: Use nodelist files
  48.                                         5: Create new Fido area
  49.                                         6: Create new QBBS area
  50.                                         7: Binkley mode on }
  51.              Swap:Byte;           { 0: No swap; 1: Disk swap; 2: EMS swap }
  52.              MinSpace:Word;
  53.              Dir:Record
  54.                     Mail,Files,Out,ArcMail,MsgBase,Dupes,
  55.                     BadEcho,Packer,Stats,NewAreas,Nodelist:String[60];
  56.                  end;
  57.              Origin:Array[1..10] of String[65];
  58.              AreaListFile:String[60];
  59.              LogFile:String[60];
  60.              LogLevel:Byte;        { 0: Important messages
  61.                                      1: Important+normal messages
  62.                                      2: Important+normal+detailed messages
  63.                                      3: Debug mode (all sort of messages) }
  64.              LogStyle:Byte;        { 0: Binkley Term; 1: FrontDoor }
  65.              Active_Options2:Byte; { Bit mapped:
  66.                                        0: Kill rcvd messages
  67.                                        1: Sort nodes
  68.                                        2: Write nodes in short form
  69.                                        3: Allow user rescan
  70.                                        5: Combine 2 tear lines
  71.                                        6: Honour RRQs
  72.                                        7: Kill packed messages }
  73.              BBSInfo:Array [1..50] of
  74.                      Record
  75.                         Zone,Net,Node,Point:Integer;
  76.                         Packer:Byte;
  77.                         CmdPw1:String[20];
  78.                         CmdPw2:String[20];
  79.                         Level:Byte;
  80.                         Misc:Integer; { Bit 1: Daily packets }
  81.                         Aka:Byte;
  82.                      end;
  83.              RouteFile:String[60];
  84.              Packer:Array[1..7] of { See DefPacker for packers and unpackers
  85.                                      assignations. Packer[7] (???) can be
  86.                                      any packer }
  87.                        Record
  88.                           Name:String[12];
  89.                           Parms:String[20];
  90.                        end;
  91.              UnPacker:Array[1..7] of
  92.                          Record
  93.                             Name:String[12];
  94.                             Parms:String[20];
  95.                          end;
  96.              DefPacker:Byte;        {1:ARC 2:ARJ 3:LZH 4:PAK 5:ZIP 6:ZOO}
  97.              Def_Misc:Byte;         { Bit mapped:
  98.                                          0: Put origin
  99.                                          1: Put tear line
  100.                                          2: Hide SEEN-BY
  101.                                          3: Strip 4d address
  102.                                          4: Add AKA's
  103.                                          5: Put domain  }
  104.              Unused:Array[1..1000] of Byte;
  105.           end;
  106.  
  107.  
  108.    AreasRecord=Record { >>>>> File AREAS.PRM <<<<< }
  109.                   Titolo   : String[40];
  110.                   Path     : String[80];
  111.                   Tipo     : Byte; {Local=1  EchoMail=2  NetMail=3
  112.                                    Passthru=4}
  113.                   WEdOrigin: Byte; { Used by WEdit }
  114.                   Tag      : String[40];
  115.                   Def_Attr : Byte;        {Bit Mapped (used by WEdit):
  116.                                                      Bit 0 : Pvt
  117.                                                      Bit 1 : Crash
  118.                                                      Bit 4 : F/A
  119.                                                      Bit 7 : Kill/Sent}
  120.                   ForwardTo: Array[1..3] Of String[60];
  121.                   Aka      : Byte;
  122.                   Misc     : Byte;  { Bits: see SetRec.Def_Misc }
  123.                   Level    : Byte;
  124.                   WMOrigin : Byte;
  125.                   Fill     : Array[1..8] of Char;
  126.                end;
  127.  
  128.  
  129. { ***** Statistics files structures ************************************* }
  130.  
  131.    Stat1=Record         { >>>>> file WMSTAT1.DAT <<<<<}
  132.             TagArea:String[30];
  133.             F:Array[1..3] of
  134.               Record
  135.                  ImpMsg,ExpMsg:Word;
  136.               end;
  137.          end;
  138.  
  139. { TagArea contains the name of the area to which statistics refer.
  140.   Record F contains number of imported (ImpMsg) and exported (ExpMsg) messages.
  141.   F[1] contains yearly informations, F[2] monthly ones and F[3] weekly ones.
  142.   From first record it is possible to obtain informations about the period
  143.   for which statistics refer.
  144.   F[1].ImpMsg contains a 4 digit number indicating the concerned year
  145.   F[2].ImpMsg contains a number in {1,2,...12} indicating the concerned month
  146.   F[3].ImpMsg contains number of days between 1970 and concerned period.
  147.   Weekly statistics are made after first Monday import.
  148.  
  149.    Stat2=Record         { >>>>> file WMSTAT2.DAT <<<<< }
  150.             Net,Node,Point:Integer;
  151.             F:Array[1..3] of
  152.               Record
  153.                  NumPktImp:Integer;
  154.                  NumMsgImp,NumBytesImp:Longint;
  155.                  NumPktExp:Integer;
  156.                  NumMsgExp,NumBytesExp:Longint;
  157.               end;
  158.          end;
  159.  
  160. { Net,Node,Point contain the address of node to which statistics refer.
  161.   Record F contains informations about number of imported packets (NumPktImp),
  162.   number of imported messages (NumMsgImp) and total dimension in bytes of
  163.   imported packets (NumBytesImp). The same informations are also present in
  164.   export (NumPktExp, NumMsgExp,NumBytesExp). F[1] contains yearly informations
  165.   F[2] the monthly ones and F[3] the weekly ones.
  166.   First record contains reserved informations and must be therefore skipped. }
  167.  
  168.  
  169.  
  170. { ***** W-Nodelist files structures **************************************** }
  171.  
  172. Files created by WNode are 4, and are used for indexing text nodelist in
  173. order to speed up seeks;
  174.  
  175. *AltNode.WNL contains a queue of nodelist files used other than NodeList.*,
  176.              so private nodelists, pointlists or alternate net nodelists.
  177.  
  178. *NodeLoc.WNL contains position of concerned field, and nodelist file in
  179.              which are contained the informations about node every record
  180.              refers to.
  181.  
  182. *SysList.WNL contains names of all Sysops alphabetically sorted and location
  183.              of relative node in NodeLoc.WNL.
  184.  
  185. *NodeRec.WNL contains indexes to obtain a quick search inside NodeLoc.WNL and
  186.              SysList.WNL. All starting positions of zones and nets, and of
  187.              sorted sysop are put in it.
  188.  
  189.  
  190.    NodeLocRec=Record             { Record of NodeLoc.WNL }
  191.                  NodeType:Byte;  { 1:Zone coordinator
  192.                                    2:Region coordinator
  193.                                    4:Host
  194.                                    8:Hub
  195.                                   16:Pvt
  196.                                   32:Hold
  197.                                   64:Down
  198.                                  128:Boss [from pointlist] }
  199.                  Zone,Net,Node,Point:Integer;
  200.                  FileNum:Byte;   { 1: Nodelist.* [newest file];
  201.                                    2: AltNode.WNL [created by WNode] }
  202.                  FilePos:Longint; { Contains absolute node position in one
  203.                                     of two files pointed by FileNum }
  204.               end;
  205.  
  206.  
  207.    SysopRec=Record               { Record of SysList.WNL }
  208.                Name:String[20];
  209.                BBSRecord:Longint;{ Position of node record in NodeLoc.WNL }
  210.             end;
  211.  
  212.  
  213.    NodeRec=Record                { Record of NodeIdx.WNL }
  214.               NodeType:Byte;     { For mapping, see NodeLocRec.NodeType.
  215.                                    Nodes reported in this field are only of
  216.                                    the following types:
  217.                                    Zone coordinator
  218.                                    Region coordinator
  219.                                    Host
  220.                                    Boss }
  221.               Number:Integer;    { The significative part of address:
  222.                                    Zone coordinator: zone number
  223.                                    Region coordinator, Host: net number
  224.                                    Boss: node number }
  225.               BBSRecord:Longint; { Position of node record in NodeLoc.WNL }
  226.               Match:Array[1..4] of Char;
  227.                                  { The first 4 character of some of the
  228.                                    sorted sysop names. One out of about 30
  229.                                    names is taken. }
  230.               SysopRecord:Longint;
  231.                                  { Position of sysop record in SysList.WNL }
  232.            end;
  233.  
  234. ───────────────────────────────────────────────────────────────────────────
  235. Note: The author reserves for himself right to change this document without
  236. advice.
  237. ───────────────────────────────────────────────────────────────────────────
  238. End of file.
  239.